package com.cmccgz.udacs_landlord_webapp.data;

import android.support.annotation.NonNull;

import com.cmccgz.udacs_landlord_webapp.bean.AccreditCardBean;
import com.cmccgz.udacs_landlord_webapp.bean.BuildingCountBean;
import com.cmccgz.udacs_landlord_webapp.bean.HouseListDataBean;
import com.cmccgz.udacs_landlord_webapp.bean.HouseManagerBean;
import com.cmccgz.udacs_landlord_webapp.bean.HousePeopleBean;
import com.cmccgz.udacs_landlord_webapp.bean.MobileBean;

import java.util.List;

/**
 * @author: Huang
 * @Descripion:
 * @date 2017/6/22 15:04
 */

public interface HouseManagerDataSource {

    interface FunctionListCallback {
        void onFunctionListLoaded(List<HouseManagerBean> list);
        void onLoadedFailed(String msg);
    }

    interface HouseListCallback {
        void onHouseListLoaded(List<HouseListDataBean> list);
        void onLoadedFailed(String msg);
    }

    interface HouseDetailCallback {
        void onHouseDetailLoaded(List<HousePeopleBean> list);
        void onLoadedFailed(String msg);
    }

    interface BuildingCountCallback {
        void onBuildingCountLoaded(List<BuildingCountBean> list);
        void onLoadedFailed(String msg);
    }

    void getFunctionList(@NonNull FunctionListCallback callback);

    void getHouseList(@NonNull String searchType,@NonNull String keyword,
                      @NonNull String oCond, @NonNull int page,
                      @NonNull HouseListCallback callback);

    void getHouseDetail(@NonNull String houseId, @NonNull HouseDetailCallback callback);

    void getBuildingCount(@NonNull String buildingId, @NonNull BuildingCountCallback callback);

    void checkout(@NonNull List<MobileBean> bean, @NonNull String houseId,@NonNull BaseCallback callback);

    void houseChange(@NonNull List<MobileBean> bean, @NonNull String oldHouseId, @NonNull String newHouseId,@NonNull BaseCallback callback);

    void accreditCard(@NonNull AccreditCardBean bean, @NonNull BaseCallback callback);
}
